﻿@model IEnumerable<FantasyDraft2.Models.Player>

@{
    ViewBag.Title = "Team Details";
}

<h2>@ViewBag.Title</h2>
<table>
    <thead>
        <th>Name</th>
        <th>Injured</th>
        <th>Benched</th>s
        <th>Assists</th>
        <th>Goal</th>
    </thead>
    @foreach (var p in Model)
    {
        <tr>
            <td>
                @p.Name
            </td>
            <td>
                @if (@p.IsInjured)
                {
                   <span style="color: green;">true</span> 
                }
                else
                {
                   <span style="color: red;">false</span> 
                }
            </td>
            <td>
                @if (@p.IsActive)
                {
                   <span style="color: green;">true</span> 
                }
                else
                {
                   <span style="color: red;">false</span> 
                }
            </td>
            <td>
                @p.Assists
            </td>
            <td>
                @p.Goals
            </td>
        </tr>
    }
</table>
<p>
    @Html.ActionLink("Back to Team Overview", "Index", "User")
</p>
